package com.qdlc.p2p.biz.executer.impl;

import org.springframework.beans.factory.config.ConfigurableBeanFactory;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Service;

import com.qdlc.p2p.biz.executer.BaseExecuter;
import com.qdlc.p2p.biz.service.UserVipUpRateService;
import com.qdlc.p2p.common.constant.Global;
import com.qdlc.p2p.common.constant.LogTplNid;
import com.qdlc.p2p.common.util.BeanUtil;

/**
 * 还款处理vip加息
 *
 * @author zlhx
 * @version 2.0
 * @date 2015-06-17 14:25
 */
@Service
@Scope(value=ConfigurableBeanFactory.SCOPE_PROTOTYPE)
public class VipUpRateRepayExecuter extends BaseExecuter {
    private String accountLogType = LogTplNid.VIP_UP_RATE_INTEREST_REPAY;

    @Override
    public String getAccountLogType() {
        return accountLogType;
    }

    @Override
    public String getLogRemark() {
        return "";
    }

    @Override
    public void extend() {
        long collectionId = (Long) Global.getTransfer().get("collectionId");
        UserVipUpRateService userVipUpRateService = (UserVipUpRateService) BeanUtil.getBean("userVipUpRateService");
        userVipUpRateService.borrowRepaySuccessVipUpRate(collectionId, accountLogType);
    }
}
